<header id="top">
    <ul id="social">
        
    </ul>
    <p class="subscribers">欢迎<span class="subscribersno">&nbsp;&nbsp;&nbsp;{$result.user_name}&nbsp;&nbsp;&nbsp;</span>
        {if condition="$Think.session.user_id!=NULL"}
        <span class="subscribersno" style="font-size: 13px;cursor: pointer;" onclick="logout();">退出</span>
        {else/}
        <span class="subscribersno" style="font-size: 13px;cursor: pointer;" onclick="login();">登录</span>
        {/if}
    </p>
    <p>
        <a href="#" rel="home">
        <img src="__STATIC__/home/img/logo.png" class="logo" alt="logo" height="69" width="299">
    </a>
    </p>
</header>
<script>
    function logout(){
        window.location.href="{:url('/home/index/logout')}";
    }

    function login(){
        window.location.href="{:url('/home/login/login')}";
    }
</script>